Congestion occurs when network devices are unable to operate as desired due to the presence of too much traffic within the network. Because of congestion, a network device may be overwhelmed with incoming traffic. Consequentially the network device may begin to operate more slowly than desired. Accordingly, congestion degrades a network's performance. Congestion can lead to packet delay or even packet loss.
Quality of Service (abbreviated QoS) is a feature that reduces congestion within a network by implementing selective packet drop. A packet is “dropped” whenever a network device that receives that packet does not forward the packet. QoS involves classifying and policing packets received by each network device. Classifying packets involves differentiating packets by class according to a policy selected by a network administrator. For each class of packets, a policing algorithm is used to perform policing by measuring the incoming traffic in that class and then comparing that measure with policing parameters selected by the network administrator.
Depending on the outcome of the comparison, the policing algorithm identifies each packet as being either “in profile” or “out of profile.” “In profile” packets are forwarded normally and are described as “permitted” traffic. “Out of profile” packets are either dropped or “marked” and are described as “policed” traffic. Marked packets are forwarded after being updated to include information identifying that those packets have been marked. Being marked increases the probability that the packet will be dropped when another device applies QoS to the packet.
Typically, policing is performed by a device or software program, referred to as a “policer,” that is included within a network device. There can be multiple forwarding engines per network device. In conventional policing, each forwarding engine performs policing independently. Distributed policing algorithms allow several forwarding engines to perform policing in a manner that reflects traffic conditions at all of the participating forwarding engines. Thus, a packet can be policed at one forwarding engine based on aggregate traffic conditions experienced by a group of forwarding engines.
Distributed policing is advantageous in that it allows the same policing policy to be applied to a class of traffic being handled by multiple independent policers. Ideally, if the rate of traffic received at each of the distributed policers is the same, each of the distributed policers should permit the same amount of traffic. However, due to various factors, this ideal state of operation may not be achieved.
Various factors can result in traffic being policed unfairly by one of the policers that is performing distributed policing. For example, each policer may send packets to the other distributed policers in order to inform the other policers of local traffic conditions. Based on these update packets, the policers can determine how much total traffic has been permitted by the group of distributed policers. However, if some of the distributed policers do not receive a particular update packet (e.g., due to packet loss within the network), different policers will maintain different total counts of permitted traffic. As a result, some policers may permit more traffic than those policers should permit, while other policers may permit less traffic. As this example shows, improved techniques for implementing distributed policing are desirable.
While the invention is susceptible to various modifications and alternative forms, specific embodiments of the invention are provided as examples in the drawings and detailed description. It should be understood that the drawings and detailed description are not intended to limit the invention to the particular form disclosed. Instead, the intention is to cover all modifications, equivalents and alternatives falling within the spirit and scope of the invention as defined by the appended claims.